import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue'
//让vue支持name声明
import vueSetupExtend from 'vite-plugin-vue-setup-extend'
const path=require('path')
//为了让vite支持@
// https://vitejs.dev/config/
export default defineConfig({
  plugins: [vue({
    reactivityTransform:true
  }), vueSetupExtend()],
  resolve: {
    alias: {  
      '@': path.resolve(__dirname, './src')
    }
  },
  css: {
    preprocessorOptions: {
      less: {
        additionalData: `
          @import "@/assets/styles/variables.less";
          @import "@/assets/styles/mixins.less";
        `
      }
    }
  }
})
